package svc

import (
	"login-hub/api/internal/config"
	"login-hub/loginrpc/loginrpcclient"

	"github.com/zeromicro/go-zero/zrpc"
)

type ServiceContext struct {
	Config   config.Config
	LoginRpc loginrpcclient.Loginrpc
}

func NewServiceContext(c config.Config) *ServiceContext {
	return &ServiceContext{
		Config:   c,
		LoginRpc: loginrpcclient.NewLoginrpc(zrpc.MustNewClient(c.LoginRpc)),
	}
}
